package com.oa.pm.service;

import com.baomidou.mybatisplus.plugins.Page;
import com.joneying.common.web.response.Resp;
import com.oa.core.PageResult;
import com.oa.core.exception.BusinessException;
import com.oa.core.exception.DataIsEmptyException;
import com.oa.pm.dto.RecruitmentAddDTO;
import com.oa.pm.dto.RecruitmentAuditDTO;
import com.oa.pm.dto.RecruitmentListDTO;
import com.oa.pm.entity.Recruitment;
import com.baomidou.mybatisplus.service.IService;
import com.oa.pm.vo.RecruitmentDetailsVO;
import com.oa.pm.vo.RecruitmentListVO;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * <p>
 * 招聘申请表 服务类
 * </p>
 *
 * @author syb123
 * @since 2019-01-22
 */
public interface IRecruitmentService extends IService<Recruitment> {
    /**
     * 自定义分页
     * @param pageNum
     * @param pageSize
     * @return
     */
    PageResult<Recruitment> findList(Integer pageNum, Integer pageSize);

    /**
    * 根据id查询
    */
    RecruitmentDetailsVO findRecruitmentById(String id);

    PageResult<RecruitmentListVO> findRecruitmentList(RecruitmentListDTO recruitmentListDTO);

    Resp add(RecruitmentAddDTO recruitmentAddDTO) throws DataIsEmptyException, BusinessException;

    Resp audit(RecruitmentAuditDTO recruitmentAuditDTO) throws DataIsEmptyException;

    void export(RecruitmentListDTO recruitmentListDTO, HttpServletResponse response);
}
